{OVERALL_HEADER}
<table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="200" valign="top">
	IF("{LOGGEDIN}"=="0"){<a href="signup.php">{LANG_JOIN}</a><br><a href="login.php">{LANG_LOGIN}</a><br>{:IF}
	IF("{LOGGEDIN}"=="1"){<a href="{SITE_URL}editprofile.php">{LANG_EDITPROFILE}</a><br>{:IF}
      <a href="{SITE_URL}add_story.php">{LANG_SUBMITS}</a><br>
	IF("{LOGGEDIN}"=="1"){<a href="{SITE_URL}logout.php">{LANG_LOGOUT}</a><br>{:IF}
      <br>
	  <strong>{LANG_CATS}</strong><br>
      <br>
      {LOOP: CATS}
	  <a href="{CATS.cat_url}">{CATS.cat_title}</a><br>
	  {/LOOP: CATS}
	  <br>
    <br></td>
    <td valign="top"><strong>{LANG_SIGNUP}</strong><br>
    <br>    <form name="form1" id="form1" method="post" action="signup.php" style="padding:0px;margin:0px;">
      <table border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="140" valign="top" style="padding-top:5px;"><strong>{LANG_USERNAME}</strong></td>
          <td><input name="username" type="text" id="username" style="width:200px;" onchange="changeuser(this,'avail');" onkeypress="changeuser(this,'avail');" onkeyUp="changeuser(this,'avail');" value="{USERNAME_FIELD}" maxlength="16">
            <br>
            <input type="button" name="avail" id="avail" value="check for availability" onclick="checkavail('username');" style="width:200px;" disabled><br>
			<span id="availres"></span>
            <br>
          <span class="error">{USERNAME_ERROR}</span></td>
        </tr>
        <tr>
          <td valign="top">&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
        <tr>
          <td valign="top" style="padding-top:5px;"><strong>{LANG_PASSWORD}</strong></td>
          <td><input name="password" type="password" id="password" style="width:200px;" maxlength="16"></td>
        </tr>
        <tr>
          <td valign="top" style="padding-top:5px;"><strong>{LANG_CONPASS}</strong></td>
          <td><input name="password2" type="password" id="password2" style="width:200px;" maxlength="16"><br>
          <span class="error">{PASSWORD_ERROR}</span></td>
        </tr>
        <tr>
          <td valign="top">&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
        <tr>
          <td valign="top" style="padding-top:5px;"><strong>{LANG_EMAILAD}</strong></td>
          <td><input name="email" type="text" id="email" style="width:200px;" value="{EMAIL_FIELD}" maxlength="255"><br>
          <span class="error">{EMAIL_ERROR}</span></td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
		<tr><td colspan="2"><table  border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><input name="agree" type="checkbox" value="1"></td>
    <td>{LANG_IAGREE} <a href="#" onClick="openWindow('{SITE_URL}html.php?id=terms','terms','width=300,height=500')">{LANG_TERMS}</a> {LANG_FORUSING} {SITE_TITLE}<br>
      <span class="error">{AGREE_ERROR}</span></td>
  </tr>
</table></td></tr>
<tr><td>&nbsp;</td><td>&nbsp;</td></tr>
        <tr align="center">
          <td colspan="2"><input type="submit" name="Submit" value="{LANG_SIGNUP}"></td>
          </tr>
      </table>
    </form></td>
  </tr>
</table>
{OVERALL_FOOTER}